// 数据模型
const Service = require('egg').Service
// 类 + 类方法的形式编写
class HomeService extends Service {
  async findUser() {
    const data = await this.ctx.app.mysql.query('select * from users;');
    return await data;
  }
}

module.exports = HomeService;